﻿using DirectService.Server.Com.ROS;
using DirectService.Server.Com.taobao.Models;
using LJLib.Net.SPI.Com;
using System.Collections.Generic;

namespace DirectService.Server.Com.taobao
{
    /// <summary>
    /// TODO: 上传SKU
    /// </summary>
    public sealed class UploadSKURequest : ITokenRequest<UploadSKUResponse>
    {
        /// <summary>
        /// 门店主体会话ID
        /// </summary>
        public string token { get; set; }
        /// <summary>
        /// 上传门店本地的产品编码，主要信息如下：
        /// skuflag: 1
        /// mtrlcode: 产品物料编码
        /// status：配置
        /// woodcode：配置1
        /// pcode：配置2
        /// mtrlid
        /// mtrlname
        /// mtrlmode
        /// unit
        /// 注意：在龙嘉系统里产品编码+三个配置码(对于独立编码产品，三个配置可以为空字符)才可以确定到具体的产品形状，即SKU
        /// </summary>
        public List<SKU> mtrlList { get; set; }


        public string GetApiName()
        {
            return "UploadSKU";
        }
    }

    /// <summary>
    /// 没有异常则为上传成功，为了避免重复上传，请区分已上传成功的
    /// </summary>
    public sealed class UploadSKUResponse : LJResponse
    {
        public List<SKU> mtrlList { get; set; }
    }
}
